<header class="header">
  <a href="{{ site.baseurl }}/" class="logo"></a>
  <nav class="menu">
    {% for menu in site.menu -%}

      {%- assign target = "" %}
      {%- if menu.target %}
        {% capture target %}target="{{ menu.target }}"{% endcapture %}
      {%- endif %}

      {%- assign href = menu.url %}
      {%- unless href contains "://" %}
        {% capture href %}{{ site.baseurl }}{{ menu.url }}{% endcapture %}
      {%- endunless -%}

      <a href="{{href}}" {{target}} class="hover-underline">{{ menu.title }}</a>
    {% endfor -%}
  </nav>
</header>
